package com.rightsidetech.system.dtos.request.news;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;
import java.io.Serializable;

@Data
public class NewsTypeSaveReq implements Serializable {

    @ApiModelProperty(value = "新闻分类名称",required = true)
    @Pattern(regexp = "^[\\u4e00-\\u9fa5a-zA-Z0-9-.]{0,30}$",message = "新闻分类名称不允许特殊字符长度最大为30")
    @NotBlank(message = "新闻分类名称不能为空")
    private String typeName;
}
